package com.leadingsoft.pwxk.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.leadingsoft.pwxk.converter.ProductMaterialConverter;
import com.leadingsoft.pwxk.dto.ProductMaterialDto;
import com.leadingsoft.pwxk.repository.ProductMaterialRepository;
import com.leadingsoft.pwxk.service.ProductMaterialService;

/**
 * @author: lipan 2018年5月17日
 * @description: ( 主要原辅材料及燃料信息 )
 * 
 */

@Service
public class ProductMaterialServiceImpl implements ProductMaterialService {

	@Autowired
	private ProductMaterialRepository productMaterialRepository;

	@Autowired
	private ProductMaterialConverter productMaterialConverter;

	@Override
	public ProductMaterialDto get(String dataid) {
		return productMaterialConverter.toDto(productMaterialRepository.findByDataid(dataid));
	}

}
